<!DOCTYPE html>
<html class="writer-html5" lang="en" >
<head>
  <meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>Understanding Spot Programming &mdash; Spot 5.0.1.1 documentation</title>
      <link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
      <link rel="stylesheet" href="../../_static/style.css" type="text/css" />
    <link rel="shortcut icon" href="../../_static/bd-favicon.png"/>
    <link rel="canonical" href="https://dev.bostondynamics.com/docs/python/understanding_spot_programming.html" />
  <!--[if lt IE 9]>
    <script src="../../_static/js/html5shiv.min.js"></script>
  <![endif]-->
  
        <script src="../../_static/jquery.js"></script>
        <script src="../../_static/_sphinx_javascript_frameworks_compat.js"></script>
        <script data-url_root="../../" id="documentation_options" src="../../_static/documentation_options.js"></script>
        <script src="../../_static/doctools.js"></script>
        <script src="../../_static/sphinx_highlight.js"></script>
    <script src="../../_static/js/theme.js"></script>
    <link rel="index" title="Index" href="../../genindex.html" />
    <link rel="search" title="Search" href="../../search.html" />
    <link rel="next" title="Python Examples" href="../../python/examples/README.html" />
    <link rel="prev" title="QuickStart" href="quickstart.html" /> 
</head>

<body class="wy-body-for-nav"> 
  <div class="wy-grid-for-nav">
    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
      <div class="wy-side-scroll">
        <div class="wy-side-nav-search" >

          
          
          <a href="../../README.html">
            
              <img src="../../_static/bd-official-white.png" class="logo" alt="Logo"/>
          </a>
              <div class="version">
                5.0.1.1
              </div>
<div role="search">
  <form id="rtd-search-form" class="wy-form" action="../../search.html" method="get">
    <input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
    <input type="hidden" name="check_keywords" value="yes" />
    <input type="hidden" name="area" value="default" />
  </form>
</div>
        </div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
              <ul class="current">
<li class="toctree-l1"><a class="reference internal" href="../concepts/README.html">Concepts</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../concepts/about_spot.html">About Spot</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/orbit/about_orbit.html">About Orbit (formerly Scout)</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/orbit/orbit_api.html">Orbit API</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/networking.html">Networking</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/base_services.html">Base services</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/geometry_and_frames.html">Geometry and Frames</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/robot_services.html">Robot services</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/estop_service.html">E-Stop</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/keepalive_service.html">KeepAlive (BETA)</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/audio_visual.html">Audio Visual</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/lease_service.html">Lease</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/developing_api_services.html">Developing API Services</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/service_customization.html">Service Customization</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/faults.html">Faults</a></li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/autonomy/README.html">Autonomy services</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/graphnav_tech_summary.html">Autonomy Technical Summary</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/autonomous_navigation_code_examples.html">Autonomous navigation code examples</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/components_of_autonomous_navigation.html">Components of autonomous navigation</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/docking.html">Docking</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/typical_autonomous_navigation_use_case.html">Typical autonomous navigation use case</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/autonomous_navigation_services.html">Autonomous navigation services</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/graphnav_service.html">GraphNav service</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/graphnav_map_structure.html">GraphNav map structure</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/graphnav_area_callbacks.html">GraphNav area callbacks</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/initialization.html">Initialization</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/localization.html">Localization</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/graphnav_and_robot_locomotion.html">GraphNav and robot locomotion</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/missions_service.html">Missions service</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/autowalk_service.html">Autowalk service</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/network_compute_bridge.html">Network compute bridge</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/auto_return.html">AutoReturn service</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/directed_exploration.html">Directed Exploration</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/autonomy/gps.html">GPS</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/choreography/README.html">Choreography</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/choreography_service.html">Choreography Service</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/move_reference.html">Move Reference Guide</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/custom_gait.html">CustomGait Reference</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/choreographer_setup.html">Choreographer Setup</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/choreographer.html">Choreographer Overview</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/robot_controls_in_choreographer.html">Robot Connections in Choreographer</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/animations_in_choreographer.html">Animations in Choreography</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/animation_file_specification.html">Animation File Format</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/choreography_in_tablet.html">Tablet Choreography Mode</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/choreography/choreography_in_autowalk.html">Choreography Actions in Autowalk</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/joint_control/README.html">Joint Control API</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../concepts/joint_control/supplemental_data.html">Supplemental Robot Information</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../concepts/joint_control/knee_torque_limits.html">Knee Torque Limits</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/arm/README.html">Spot Arm</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../concepts/arm/arm_specification.html">Arm and Gripper Specification</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/arm/arm_concepts.html">Concepts</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/arm/arm_services.html">Services</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../concepts/data.html">Spot Data</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../concepts/data_acquisition_overview.html">Data Acquisition Overview</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/data_acquisition_output.html">Data Acquisition Output</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/writing_services_for_data_acquisition.html">Integrate Payloads with the API</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/data_buffer_overview.html">Data Buffer Overview</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/bddf.html">BDDF File Format</a></li>
<li class="toctree-l3"><a class="reference internal" href="../concepts/data_acquisition_thermal_raw.html">Thermal Raw Data Format</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1 current"><a class="reference internal" href="README.html">Python</a><ul class="current">
<li class="toctree-l2"><a class="reference internal" href="quickstart.html">Quickstart</a></li>
<li class="toctree-l2 current"><a class="current reference internal" href="#">Understanding Spot Programming</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../python/examples/README.html">Examples</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/basic_service_examples.html">Basic Service Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/hello_spot/README.html">Hello Spot</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/directory/README.html">Directory</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_robot_state/README.html">Get Robot State</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_robot_state_async/README.html">Get Robot State Async</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_image/README.html">Get Image</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_world_objects/README.html">Get World Objects</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_mission_state/README.html">Get Mission State</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/estop/README.html">E-Stop</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/time_sync/README.html">Time Sync</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/comms_test/README.html">Comms Test</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/disable_ir_emission/README.html">IR Enable/Disable</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/reset_safety_stop/README.html">Reset Safety Stop</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/audio_visual/audio_visual_params/README.html">Audio Visual Params</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/audio_visual/audio_visual_behaviors/README.html">Audio Visual Behaviors</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/robot_behavior_examples.html">Robot Behavior and Commands Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/stance/README.html">Stance</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/frame_trajectory_command/README.html">Frame Trajectory</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/spot_light/README.html">Spot Light</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/upload_choreographed_sequence/README.html">Upload Choreographed Sequence</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/xbox_controller/README.html">Xbox Controller</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/wasd/README.html">WASD</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/docking/README.html">Docking</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/animation_recorder/README.html">Animation Recorder</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/auto_return/README.html">Auto Return</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/fan_command/README.html">Fan Commands</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_wasd/README.html">ARM WASD</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/arm_examples.html">Arm Command Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_simple/README.html">Simple Arm Motion</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_stow_unstow/README.html">Stow/unstow Arm</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_freeze/README.html">Arm Freeze</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_and_mobility_command/README.html">Arm and Mobility Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_with_body_follow/README.html">Arm Command with Body Following</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_constrained_manipulation/README.html">Arm Constrained Manipulation</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_trajectory/README.html">Arm Trajectory</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_trajectory/README.html#long-trajectory">Long Trajectory</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_joint_move/README.html">Arm Joint Move Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_force_control/README.html">Arm Force Control Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_grasp/README.html">Arm Grasp Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_grasp_carry_overrides/README.html">Arm Grasp and Carry Overrides</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_gaze/README.html">Arm Gaze Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_surface_contact/README.html">Arm Command with Surface Contact</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_door/README.html">Arm Door Opening Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_walk_to_object/README.html">Walk to And Pick Up Object</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_gcode/README.html">Writing Gcode</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/gripper_camera_params/README.html">Gripper Camera Parameters</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_impedance_control/README.html">Arm Impedance Control</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/inverse_kinematics/README.html">Inverse Kinematics</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/arm_wasd/README.html">Arm WASD</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/joint_control/README.html">Wiggle Arm</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/payloads_examples.html">Payloads and Registration Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/payloads/README.html">Payloads</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/self_registration/README.html">Self Registration</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/service_faults/README.html">Faults</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/velodyne_client/README.html">Velodyne</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/core_io_gpio/README.html">CORE I/O GPIO</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/metrics_over_coreio/README.html">Overview</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/metrics_over_coreio/README.html#usage">Usage</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/metrics_over_coreio/README.html#components">Components</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/metrics_over_coreio/README.html#recommended-debugging">Recommended debugging</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/extensions/README.html">Extensions</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/perception_world_objects_examples.html">Perception and World Objects Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_image/README.html">Get Image</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_world_objects/README.html">Get World Objects</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/world_object_with_image_coordinates/README.html">World Object With Image Coordinates</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/world_object_mutations/README.html">World Object Mutations</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/visualizer/README.html">Visualizer</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/gripper_camera_params/README.html">Gripper Camera Parameters</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/spot_cam/README.html">Spot CAM Services</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/spot_cam/README.html#spot-cam-video-core-io-extension-example">Spot Cam Video Core IO Extension Example</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/stitch_front_images/README.html">Stitch Front Images</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_depth_plus_visual_image/README.html">Project Depth Data on Visual Images</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/service_customization/custom_parameter_image_server/README.html">Custom Parameter Image Server</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/fiducial_follow/README.html">Fiducial Follow</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/spot_tensorflow_detector/README.html">Tensorflow Detector</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/service_customization/custom_parameter_ncb_worker/README.html">Custom Parameter Tensorflow Detector</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/network_compute_bridge/README.html">Machine Learning with the Network Compute Bridge</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/network_compute_bridge/fire_extinguisher_server/README.html">Fire Extinguisher Detector with the Network Compute Bridge</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/ray_cast/README.html">Ray Cast</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/user_nogo_regions/README.html">No-Go Regions</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/gps_service/README.html">GPS</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/logging_examples.html">Logging Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/bddf_download/README.html">BDDF Download</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/data_buffer/README.html">Data Buffer</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/data_service/README.html">Data Service</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/logging/README.html">Logging</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/log_status/README.html">Log Status</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/data_acquisition_examples.html">Data Acquisition Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/data_acquisition_service/README.html">Data Acquisition Service</a><ul>
<li class="toctree-l5"><a class="reference internal" href="../../python/examples/data_acquisition_service/signals_coreio_modem_plugin/README.html">Modem Signals</a></li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/service_faults/README.html">Faults</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/service_customization/custom_parameter_image_server/README.html">Custom Parameter Image Service</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/service_customization/custom_parameters_data_acquisition/README.html">Custom Parameter Data Acquisition Plugin</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_image/README.html">Test Image Service Implementation with Get Image</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/post_docking_callbacks/README.html">Post Docking Callbacks</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/cloud_upload/README.html">Cloud Upload</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/comms_mapping/README.html">Comms image service</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/comms_mapping/README.html#how-to-use">How to use</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/data_acquisition_service/signals_coreio_modem_plugin/README.html">CoreIO Modem Signals Plugin</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/tester_programs/README.html">Tester Programs</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/autonomy_and_missions_examples.html">Autonomy and Missions Examples</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/graph_nav_anchoring_optimization/README.html">Graph Nav Anchoring Optimization</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/graph_nav_command_line/README.html">GraphNav and Recording Service Command Line Interfaces</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/graph_nav_command_line/README.html#example-programs">Example Programs</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/graph_nav_extract_point_cloud/README.html">Graph Nav Extract Point Cloud</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/graph_nav_view_map/README.html">Graph Nav View Map</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/graph_nav_view_gps/README.html">Graph Nav View GPS Data</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/get_mission_state/README.html">Get Mission State</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/remote_mission_service/README.html">Remote Mission Service</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/mission_question_answerer/README.html">Mission Question Answerer</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/mission_recorder/README.html">Mission Recorder</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/replay_mission/README.html">Replay Mission</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/post_docking_callbacks/README.html">Post Docking Callbacks</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/area_callback/README.html">Area Callbacks</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/edit_autowalk/README.html">Edit Autowalk</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/record_autowalk/README.html">Record Autowalk</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/extract_images_from_walk/README.html">Extract Images from Autowalk</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/network_request_callback/README.html">Network Request Callback</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/network_request_callback/README.html#id1">Network Request Callback</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/remote_mission_service/spot_check/README.html">SpotCheck Mission Service</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/joint_control_examples.html">Joint Control API Examples</a></li>
<li class="toctree-l3"><a class="reference internal" href="../../python/examples/docs/orbit.html">Orbit</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/hello_orbit/README.html">Hello Orbit</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/export_run_archives/README.html">Export Run Archives</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/export_site_walk_archives/README.html">Export Sitewalk Archives</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/anomalies/README.html">Anomalies</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/schedule_mission/README.html">Schedule Mission</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/runs_response/README.html">Runs Response</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/send_robot_back_to_dock/README.html">Return to Dock</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/toggle_mission_based_on_weather/README.html">Mission Toggle</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/webhook/README.html">Webhook</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/backups/README.html">Backups</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/webhook_integration/README.html">Webhook Integrations</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/examples/orbit/webhook_integration/README.html#example-overview">Example Overview</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../../python/README.html">Python Reference Guide</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/README.html">Client</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/area_callback.html">Area Callback</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/area_callback_region_handler_base.html">Area Callback Region Handler</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/area_callback_service_runner.html">Area Callback Service Runner</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/area_callback_service_servicer.html">Area Callback Servicer</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/area_callback_service_utils.html">Area Callback Service Utils</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/arm_surface_contact.html">Arm Surface Contact</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/async_tasks.html">Async Tasks</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/audio_visual.html">Audio Visual</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/audio_visual_helpers.html">Audio Visual Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/auth.html">Auth</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/auto_return.html">Auto Return</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/autowalk.html">Autowalk</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/bddf.html">BDDF</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/bddf_download.html">BDDF Download</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/channel.html">Channel</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/command_line.html">Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/common.html">Common</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_acquisition.html">Data Acquisition</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_acquisition_helpers.html">Data Acquisition Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_acquisition_plugin.html">Data Acquisition Plugin</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_acquisition_plugin_service.html">Data Acquisition Plugin Service</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_acquisition_store.html">Data Acquisition Store</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_buffer.html">Data Buffer</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_chunk.html">Data Chunk</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/data_service.html">Data Service</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/directory_registration.html">Directory Registration</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/directory.html">Directory</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/docking.html">Docking</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/door.html">Door</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/estop.html">E-Stop</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/error_callback_result.html">Error Callback Result</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/exceptions.html">Exceptions</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/fault.html">Fault</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/frame_helpers.html">Frame Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/graph_nav.html">Graph Nav</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/gripper_camera_param.html">Gripper Camera Params</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/gps/README.html">GPS</a><ul>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/gps/aggregator_client.html">Aggregator Client</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/gps/gps_listener.html">GPS Listener</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/gps/NMEAParser.html">NMEA Parser</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/gps/ntrip_client.html">NTRIP Client</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/gps/registration_client.html">Registration Client</a></li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/image.html">Image</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/image_service_helpers.html">Image Service Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/inverse_kinematics.html">Inverse Kinematics</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/ir_enable_disable.html">IR Enable/Disable</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/keepalive.html">Keep Alive</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/lease.html">Lease</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/lease_resource_hierarchy.html">Lease Resource Hierarchy</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/lease_validator.html">Lease Validator</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/license.html">License</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/local_grid.html">Local Grid</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/log_status.html">Log Status</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/math_helpers.html">Math Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/manipulation_api_client.html">Manipulation API</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/map_processing.html">Map Processing</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/metrics_logging.html">Metrics Logging</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/network_compute_bridge_client.html">Network Compute Bridge</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/payload_registration.html">Payload Registration</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/payload_software_update.html">Payload Software Update</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/payload_software_update_initiation.html">Payload Software Update Initiation</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/payload.html">Payload</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/point_cloud.html">Point Cloud</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/power.html">Power</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/processors.html">Processors</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/ray_cast.html">Ray casting</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/recording.html">Recording</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/robot_command.html">Robot Command</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/robot_id.html">Robot ID</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/robot.html">Robot</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/robot_state.html">Robot State</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/sdk.html">SDK</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/server_util.html">Server Util</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/service_customization_helpers.html">Service Customization Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/signals_helpers.html">Signals Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/README.html">Spot CAM</a><ul>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/audio.html">Audio</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/compositor.html">Compositor</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/health.html">Health</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/lighting.html">Lighting</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/lights_helper.html">Lights Helper</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/media_log.html">Media Log</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/network.html">Network</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/power.html">Power</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/ptz.html">PTZ</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/streamquality.html">Stream Quality</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_cam/version.html">Version</a></li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/spot_check.html">Spot Check</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/time_sync.html">Time Sync</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/token_cache.html">Token Cache</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/token_manager.html">Token Manager</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/units_helpers.html">Units Helpers</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/util.html">Util</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-client/src/bosdyn/client/world_object.html">World Object</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/README.html">Core</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/README.html">BDDF</a><ul>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/base_data_reader.html">Base Data Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/block_writer.html">Block Writer</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/bosdyn.html">BDDF Conventions</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/common.html">Common</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/data_reader.html">Data Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/data_writer.html">Data Writer</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/file_indexer.html">File Indexer</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/grpc_proto_reader.html">GRPC Proto Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/grpc_reader.html">GRPC Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/grpc_service_reader.html">GRPC Service Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/grpc_service_writer.html">GRPC Service Writer</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/message_reader.html">Message Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/pod_series_reader.html">POD Series Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/pod_series_writer.html">POD Series Writer</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/protobuf_channel_reader.html">Protobuf Channel Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/protobuf_reader.html">Protobuf Reader</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/protobuf_series_writer.html">Protobuf Series Writer</a></li>
<li class="toctree-l5"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/bddf/stream_data_reader.html">Stream Data Reader</a></li>
</ul>
</li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/geometry.html">Geometry</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/util.html">Util</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-core/src/bosdyn/deprecated.html">Deprecated</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/bosdyn-mission/src/bosdyn/mission/README.html">Mission</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-mission/src/bosdyn/mission/client.html">Client</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-mission/src/bosdyn/mission/constants.html">Constants</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-mission/src/bosdyn/mission/exceptions.html">Exceptions</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-mission/src/bosdyn/mission/remote_client.html">Remote Client</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-mission/src/bosdyn/mission/server_util.html">Server Util</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-mission/src/bosdyn/mission/util.html">Util</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/bosdyn-choreography-client/src/bosdyn/choreography/client/README.html">Choreography</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-choreography-client/src/bosdyn/choreography/client/choreography.html">Choreography</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-choreography-client/src/bosdyn/choreography/client/animation_file_to_proto.html">Animation File to Proto</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-choreography-client/src/bosdyn/choreography/client/animation_file_conversion_helpers.html">Animation File to Proto Helpers</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/bosdyn-orbit/src/bosdyn/orbit/README.html">Orbit (formerly Scout)</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-orbit/src/bosdyn/orbit/client.html">Client</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-orbit/src/bosdyn/orbit/utils.html">Utils</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-orbit/src/bosdyn/orbit/exceptions.html">Exceptions</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../../python/bosdyn-scout/src/bosdyn/scout/README.html">Scout (deprecated)</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-scout/src/bosdyn/scout/client.html">Client</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-scout/src/bosdyn/scout/utils.html">Utils</a></li>
<li class="toctree-l4"><a class="reference internal" href="../../python/bosdyn-scout/src/bosdyn/scout/exceptions.html">Exceptions</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="fetch_tutorial/fetch1.html">Fetch Tutorial</a><ul>
<li class="toctree-l3"><a class="reference internal" href="fetch_tutorial/fetch2.html">Part 2: Training the Model</a></li>
<li class="toctree-l3"><a class="reference internal" href="fetch_tutorial/fetch3.html">Part 3: Evaluating the Model</a></li>
<li class="toctree-l3"><a class="reference internal" href="fetch_tutorial/fetch4.html">Part 4: Autonomous Pick Up</a></li>
<li class="toctree-l3"><a class="reference internal" href="fetch_tutorial/fetch5.html">Part 5: Detecting People and Playing Fetch</a></li>
<li class="toctree-l3"><a class="reference internal" href="fetch_tutorial/fetch6.html">Part 6: Running the model on Core IO</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="daq_tutorial/daq1.html">Data Collection Tutorial</a><ul>
<li class="toctree-l3"><a class="reference internal" href="daq_tutorial/daq2.html">Part 2: Capturing images</a></li>
<li class="toctree-l3"><a class="reference internal" href="daq_tutorial/daq3.html">Part 3: Capturing other data</a></li>
<li class="toctree-l3"><a class="reference internal" href="daq_tutorial/daq4.html">Part 4: Deploying to the CORE I/O</a></li>
<li class="toctree-l3"><a class="reference internal" href="daq_tutorial/daq5.html">Part 5: Collecting data</a></li>
<li class="toctree-l3"><a class="reference internal" href="daq_tutorial/daq6.html">Part 6: Processing collected data</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../payload/README.html">Payloads</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../payload/payload_configuration_requirements.html">Payload configuration requirements</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/mechanical_interfaces.html">Mechanical interfaces</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/robot_mounting_rails.html">Robot mounting rails</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/guidelines_for_robust_payload_design.html">Guidelines for robust payload design</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/robot_electrical_interface.html">Robot electrical interface</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/coreio_documentation.html">CORE I/O Documentation</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/coreio_openvpn_extension.html">CORE I/O OpenVPN Extension</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/configuring_payload_software.html">Configuring payload software</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/docker_containers.html">Dockerize payload software</a></li>
<li class="toctree-l2"><a class="reference internal" href="../payload/spot_core_documentation.html">Pre-3.2 Spot CORE Documentation</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../payload/spot_core_portainer.html">Configuring Docker containers in SpotCORE</a></li>
<li class="toctree-l3"><a class="reference internal" href="../payload/spot_core_cockpit.html">Spot CORE system management tool: Cockpit</a></li>
<li class="toctree-l3"><a class="reference internal" href="../payload/spot_core_vnc.html">Spot CORE VNC</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../protos/README.html">API Protocol</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../protos/style_guide.html">Style Guide</a></li>
<li class="toctree-l2"><a class="reference internal" href="../../protos/bosdyn/api/README.html">Proto Reference Guide</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../../protos/bosdyn/api/proto_reference.html">Protos</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../release_notes.html">Release Notes</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/boston-dynamics/spot-sdk">SDK Repository</a></li>
</ul>

        </div>
      </div>
    </nav>

    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
          <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
          <a href="../../README.html">Spot</a>
      </nav>

      <div class="wy-nav-content">
        <div class="rst-content">
          <div role="navigation" aria-label="Page navigation">
  <ul class="wy-breadcrumbs">
      <li><a href="../../README.html" class="icon icon-home" aria-label="Home"></a></li>
          <li class="breadcrumb-item"><a href="README.html">Python Library</a></li>
      <li class="breadcrumb-item active">Understanding Spot Programming</li>
      <li class="wy-breadcrumbs-aside">
      </li>
  </ul>
  <hr/>
</div>
          <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
           <div itemprop="articleBody">
             
  <!--
Copyright (c) 2023 Boston Dynamics, Inc.  All rights reserved.

Downloading, reproducing, distributing or otherwise using the SDK Software
is subject to the terms and conditions of the Boston Dynamics Software
Development Kit License (20191101-BDSDK-SL).
--><section id="understanding-spot-programming">
<h1>Understanding Spot Programming<a class="headerlink" href="#understanding-spot-programming" title="Permalink to this heading"></a></h1>
<p>This guide will help you understand the programming principles that drive Spot and the Spot Python SDK.</p>
<!--ts--><ul class="simple">
<li><p><a class="reference external" href="#fundamental-robot-services">Fundamental Robot Services</a></p>
<ul>
<li><p><a class="reference external" href="#understanding-the-id-command">Understanding the “id” command</a></p></li>
<li><p><a class="reference external" href="#listing-services">Listing Services</a></p></li>
</ul>
</li>
<li><p><a class="reference external" href="#how-to-setup-and-command-spot-to-move">Understanding How to Setup and Command Spot to Move</a>
_ <a class="reference external" href="#create-the-sdk-object">Create the SDK object</a>
_ <a class="reference external" href="#create-a-robot-object">Create a Robot object</a>
_ <a class="reference external" href="#retrieve-the-robot-id">Retrieve the Robot ID</a>
_ <a class="reference external" href="#blocking-vs-asynchronous-spot-python-sdk-functions">Blocking vs. Asynchronous Spot Python SDK functions</a>
_ <a class="reference external" href="#inspecting-robot-state">Inspecting robot state</a>
_ <a class="reference external" href="#services-and-authentication">Services and Authentication</a>
_ <a class="reference external" href="#retrieving-robot-state">Retrieving Robot State</a>
_ <a class="reference external" href="#robot-state-was-a-message-messages-are-defined-by-protobufs">Robot State was a Message, Messages are defined by Protobufs</a>
_ <a class="reference external" href="#capture-and-view-camera-images">Capture and View Camera images</a>
_ <a class="reference external" href="#configuring-motor-power-authority-software-e-stop">Configuring “Motor Power Authority” (software E-Stop)</a>
_ <a class="reference external" href="#create-and-register-an-e-stop-endpoint">Create and register an E-Stop Endpoint</a>
_ <a class="reference external" href="#clear-the-e-stop">Clear the E-Stop</a>
_ <a class="reference external" href="#taking-ownership-of-spot-leases">Taking ownership of Spot (Leases)</a>
_ <a class="reference external" href="#powering-on-the-robot">Powering on the robot</a>
_ <a class="reference external" href="#establishing-timesync">Establishing timesync</a>
_ <a class="reference external" href="#commanding-the-robot">Commanding the robot</a> * <a class="reference external" href="#powering-off-the-robot">Powering off the robot</a></p></li>
</ul>
<!--te--><section id="fundamental-robot-services">
<h2>Fundamental Robot Services<a class="headerlink" href="#fundamental-robot-services" title="Permalink to this heading"></a></h2>
<section id="understanding-the-id-command">
<h3>Understanding the “id” command<a class="headerlink" href="#understanding-the-id-command" title="Permalink to this heading"></a></h3>
<p>The “id” command is one of the simplest Spot commands, so it’s useful to understand how it works, since every command to Spot performs many of the same basic functions.</p>
<p>Specify the verbose flag with <code class="docutils literal notranslate"><span class="pre">--verbose</span></code> , and you’ll get a lot of information! We’ll explain the pieces…</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span>$ python -m bosdyn.client --verbose 192.168.80.3 id
2020-03-26 17:30:27,571 - DEBUG - Creating standard Sdk, cert glob: &quot;None&quot;
2020-03-26 17:30:27,610 - DEBUG - Created client for robot-id
2020-03-26 17:30:27,615 - DEBUG - Created channel to 192.168.80.3 at port 443 with authority id.spot.robot
...
</pre></div>
</div>
<p>The first output line creates a Spot SDK object. All Spot API programs start this way.</p>
<p>Note that the output text itself demonstrates Spot’s use of Python’s <a class="reference external" href="https://docs.python.org/3/library/logging.html">logging facility</a>, we recommend you perform your logging with the same.</p>
<p>The third line creates a <code class="docutils literal notranslate"><span class="pre">client</span></code> of Spot’s <code class="docutils literal notranslate"><span class="pre">robot-id</span></code> service. The Spot API exposes on-robot capabilities via a set of network-accessible services - similar to a <a class="reference external" href="https://en.wikipedia.org/wiki/Microservices">microservice</a> architecture.</p>
<p>The final line of output above shows the command initiating a gRPC channel to Spot. All communication to the robot is over a secure HTTPS connection. Spot API uses <a class="reference external" href="https://grpc.io">gRPC</a> as its underlying RPC (Remote Procedure Call) transport. gRPC is a high-performance networking connection for services which supports a wide variety of programming environments. gRPC uses <a class="reference external" href="https://developers.google.com/protocol-buffers/">Protocol Buffers</a> as the messaging format, which has a compact over-the-wire representation and supports backwards and forwards compatibility.</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="mi">2020</span><span class="o">-</span><span class="mi">03</span><span class="o">-</span><span class="mi">26</span> <span class="mi">17</span><span class="p">:</span><span class="mi">30</span><span class="p">:</span><span class="mi">27</span><span class="p">,</span><span class="mi">616</span> <span class="o">-</span> <span class="n">DEBUG</span> <span class="o">-</span> <span class="n">blocking</span> <span class="n">request</span><span class="p">:</span> <span class="sa">b</span><span class="s1">&#39;/bosdyn.api.RobotIdService/GetRobotId&#39;</span>
<span class="n">header</span> <span class="p">{</span>
  <span class="n">request_timestamp</span> <span class="p">{</span>
    <span class="n">seconds</span><span class="p">:</span> <span class="mi">1585258227</span>
    <span class="n">nanos</span><span class="p">:</span> <span class="mi">616570624</span>
  <span class="p">}</span>
  <span class="n">client_name</span><span class="p">:</span> <span class="s2">&quot;BosdynClientbblank02:__main__.py-28906&quot;</span>
<span class="p">}</span>
</pre></div>
</div>
<p>In the above output, a blocking <code class="docutils literal notranslate"><span class="pre">GetRobotId</span></code> RPC can be seen being made to the <code class="docutils literal notranslate"><span class="pre">bosdyn.api.RobotIdService</span></code>.</p>
<p>Finally, the RobotIdService responds to the GetRobotId RPC with a response including information about the robot.</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="mi">2020</span><span class="o">-</span><span class="mi">03</span><span class="o">-</span><span class="mi">26</span> <span class="mi">17</span><span class="p">:</span><span class="mi">30</span><span class="p">:</span><span class="mi">27</span><span class="p">,</span><span class="mi">650</span> <span class="o">-</span> <span class="n">DEBUG</span> <span class="o">-</span> <span class="n">response</span><span class="p">:</span> <span class="sa">b</span><span class="s1">&#39;/bosdyn.api.RobotIdService/GetRobotId&#39;</span>
<span class="n">header</span> <span class="p">{</span>
  <span class="n">request_header</span> <span class="p">{</span>
    <span class="n">request_timestamp</span> <span class="p">{</span>
      <span class="n">seconds</span><span class="p">:</span> <span class="mi">1585258227</span>
      <span class="n">nanos</span><span class="p">:</span> <span class="mi">616570624</span>
    <span class="p">}</span>
    <span class="n">client_name</span><span class="p">:</span> <span class="s2">&quot;BosdynClientbblank02:__main__.py-28906&quot;</span>
  <span class="p">}</span>
  <span class="n">request_received_timestamp</span> <span class="p">{</span>
    <span class="n">seconds</span><span class="p">:</span> <span class="mi">1585258226</span>
    <span class="n">nanos</span><span class="p">:</span> <span class="mi">224952738</span>
  <span class="p">}</span>
  <span class="n">response_timestamp</span> <span class="p">{</span>
    <span class="n">seconds</span><span class="p">:</span> <span class="mi">1585258226</span>
    <span class="n">nanos</span><span class="p">:</span> <span class="mi">224990830</span>
  <span class="p">}</span>
  <span class="n">error</span> <span class="p">{</span>
    <span class="n">code</span><span class="p">:</span> <span class="n">CODE_OK</span>
  <span class="p">}</span>
  <span class="n">request</span> <span class="p">{</span>
    <span class="n">type_url</span><span class="p">:</span> <span class="s2">&quot;type.googleapis.com/bosdyn.api.RobotIdRequest&quot;</span>
    <span class="n">value</span><span class="p">:</span> <span class="s2">&quot;</span><span class="se">\n</span><span class="s2">6</span><span class="se">\n\014\010\363\275\364\363\005\020\200\276\200\246\002\022</span><span class="s2">&amp;BosdynClientbblank02:__main__.py-28906&quot;</span>
  <span class="p">}</span>
<span class="p">}</span>
<span class="n">robot_id</span> <span class="p">{</span>
  <span class="n">serial_number</span><span class="p">:</span> <span class="s2">&quot;beta-BD-90490007&quot;</span>
  <span class="n">species</span><span class="p">:</span> <span class="s2">&quot;spot&quot;</span>
  <span class="n">version</span><span class="p">:</span> <span class="s2">&quot;V3&quot;</span>
  <span class="n">software_release</span> <span class="p">{</span>
    <span class="n">version</span> <span class="p">{</span>
      <span class="n">major_version</span><span class="p">:</span> <span class="mi">2</span>
    <span class="p">}</span>
    <span class="n">changeset_date</span> <span class="p">{</span>
      <span class="n">seconds</span><span class="p">:</span> <span class="mi">1583941992</span>
    <span class="p">}</span>
    <span class="n">changeset</span><span class="p">:</span> <span class="s2">&quot;b11205d698e&quot;</span>
    <span class="n">install_date</span> <span class="p">{</span>
      <span class="n">seconds</span><span class="p">:</span> <span class="mi">1583953617</span>
    <span class="p">}</span>
  <span class="p">}</span>
  <span class="n">nickname</span><span class="p">:</span> <span class="s2">&quot;beta29&quot;</span>
  <span class="n">computer_serial_number</span><span class="p">:</span> <span class="s2">&quot;02-19904-9903&quot;</span>
<span class="p">}</span>
</pre></div>
</div>
</section>
<section id="listing-services">
<h3>Listing services<a class="headerlink" href="#listing-services" title="Permalink to this heading"></a></h3>
<p>The following command lists all of the services available on the robot. Note the <code class="docutils literal notranslate"><span class="pre">robot-id</span></code> service is listed, which we just used in the previous section. Services are what you communicate with on Spot, use them to issue commands, retrieve information, etc.</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span>$ python -m bosdyn.client --user user --password password 192.168.80.3 dir list
name                             type                                              authority                                   tokens
------------------------------------------------------------------------------------------------------------------------------------
auth                             bosdyn.api.AuthService                            auth.spot.robot
directory                        bosdyn.api.DirectoryService                       api.spot.robot                              user
directory-registration           bosdyn.api.DirectoryRegistrationService           api.spot.robot                              user
estop                            bosdyn.api.EstopService                           estop.spot.robot                            user
graph-nav-service                bosdyn.api.graph_nav.GraphNavService              graph-nav.spot.robot                        user
image                            bosdyn.api.ImageService                           api.spot.robot                              user
lease                            bosdyn.api.LeaseService                           api.spot.robot                              user
...
</pre></div>
</div>
<p>See the Concept documents for more details about <a class="reference internal" href="../concepts/README.html"><span class="doc">Spot’s API Architecture</span></a>.</p>
</section>
</section>
<section id="how-to-setup-and-command-spot-to-move">
<h2>How to Setup and Command Spot to Move<a class="headerlink" href="#how-to-setup-and-command-spot-to-move" title="Permalink to this heading"></a></h2>
<p>It is useful to run Spot from the command line to understand the basics for commanding Spot.</p>
<p>Start up a python interpreter and import the bosdyn.client package - this should work assuming you’ve successfully completed our <a class="reference internal" href="quickstart.html"><span class="doc">Spot Python SDK Quickstart</span></a>.</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>python
Python<span class="w"> </span><span class="m">3</span>.6.8<span class="w"> </span><span class="o">(</span>default,<span class="w"> </span>Jan<span class="w"> </span><span class="m">14</span><span class="w"> </span><span class="m">2019</span>,<span class="w"> </span><span class="m">11</span>:02:34<span class="o">)</span>
<span class="o">[</span>GCC<span class="w"> </span><span class="m">8</span>.0.1<span class="w"> </span><span class="m">20180414</span><span class="w"> </span><span class="o">(</span>experimental<span class="o">)</span><span class="w"> </span><span class="o">[</span>trunk<span class="w"> </span>revision<span class="w"> </span><span class="m">259383</span><span class="o">]]</span><span class="w"> </span>on<span class="w"> </span>linux
Type<span class="w"> </span><span class="s2">&quot;help&quot;</span>,<span class="w"> </span><span class="s2">&quot;copyright&quot;</span>,<span class="w"> </span><span class="s2">&quot;credits&quot;</span><span class="w"> </span>or<span class="w"> </span><span class="s2">&quot;license&quot;</span><span class="w"> </span><span class="k">for</span><span class="w"> </span>more<span class="w"> </span>information.
&gt;&gt;&gt;<span class="w"> </span>import<span class="w"> </span>bosdyn.client
</pre></div>
</div>
<section id="create-the-sdk-object">
<h3>Create the SDK object<a class="headerlink" href="#create-the-sdk-object" title="Permalink to this heading"></a></h3>
<p>All Boston Dynamics API programs start by creating an SDK object with a client name argument. The client name is used to help with debugging, and does not have any semantic information - so use whatever string is helpful for you.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">sdk</span> <span class="o">=</span> <span class="n">bosdyn</span><span class="o">.</span><span class="n">client</span><span class="o">.</span><span class="n">create_standard_sdk</span><span class="p">(</span><span class="s1">&#39;understanding-spot&#39;</span><span class="p">)</span>
</pre></div>
</div>
</section>
<section id="create-a-robot-object">
<h3>Create a robot object<a class="headerlink" href="#create-a-robot-object" title="Permalink to this heading"></a></h3>
<p>To retrieve the robot id like we did in <a class="reference internal" href="quickstart.html"><span class="doc">Spot Python SDK Quickstart</span></a> we’ll first need to create a <code class="docutils literal notranslate"><span class="pre">robot</span></code> object, using its network address as an argument. In this example, we only create one <code class="docutils literal notranslate"><span class="pre">robot</span></code> object, but it is possible to create and control multiple robots in the same program with the Boston Dynamics API.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">robot</span> <span class="o">=</span> <span class="n">sdk</span><span class="o">.</span><span class="n">create_robot</span><span class="p">(</span><span class="s1">&#39;192.168.80.3&#39;</span><span class="p">)</span>
</pre></div>
</div>
</section>
<section id="retrieve-the-robot-id">
<h3>Retrieve the Robot ID<a class="headerlink" href="#retrieve-the-robot-id" title="Permalink to this heading"></a></h3>
<p>As discussed earlier, Spot exposes its capability via a number of services. The Boston Dynamics Python API has a corresponding set of clients for each service, which are created off of the robot object.</p>
<p>Let’s create a <code class="docutils literal notranslate"><span class="pre">RobotIdClient</span></code> of the <code class="docutils literal notranslate"><span class="pre">robot-id</span></code> service, and then retrieve id information:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">id_client</span> <span class="o">=</span> <span class="n">robot</span><span class="o">.</span><span class="n">ensure_client</span><span class="p">(</span><span class="s1">&#39;robot-id&#39;</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">id_client</span><span class="o">.</span><span class="n">get_id</span><span class="p">()</span>
<span class="go">serial_number: &quot;beta-BD-90490007&quot;</span>
<span class="go">species: &quot;spot&quot;</span>
<span class="go">...</span>
</pre></div>
</div>
</section>
<section id="blocking-vs-asynchronous-spot-python-sdk-functions">
<h3>Blocking vs. Asynchronous Spot Python SDK functions<a class="headerlink" href="#blocking-vs-asynchronous-spot-python-sdk-functions" title="Permalink to this heading"></a></h3>
<p>The <code class="docutils literal notranslate"><span class="pre">get_id()</span></code> call above is blocking - it will not complete until after the RPC completes. It is possible to tweak parameters for the call, such as a timeout for how long to wait. The following example sets a too short timeout and fails…</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">id_client</span><span class="o">.</span><span class="n">get_id</span><span class="p">(</span><span class="n">timeout</span><span class="o">=</span><span class="mf">0.0001</span><span class="p">)</span>
<span class="gt">Traceback (most recent call last):</span>
  File <span class="nb">&quot;/mnt/c/spot_v2_0/bblank_spot_v2_0_env/lib/python3.6/site-packages/bosdyn/client/common.py&quot;</span>, line <span class="m">290</span>, in <span class="n">call</span>
<span class="w">    </span><span class="n">response</span> <span class="o">=</span> <span class="n">rpc_method</span><span class="p">(</span><span class="n">request</span><span class="p">,</span> <span class="o">**</span><span class="n">kwargs</span><span class="p">)</span>
  File <span class="nb">&quot;/mnt/c/spot_v2_0/bblank_spot_v2_0_env/lib/python3.6/site-packages/grpc/_channel.py&quot;</span>, line <span class="m">826</span>, in <span class="n">__call__</span>
<span class="w">    </span><span class="k">return</span> <span class="n">_end_unary_response_blocking</span><span class="p">(</span><span class="n">state</span><span class="p">,</span> <span class="n">call</span><span class="p">,</span> <span class="kc">False</span><span class="p">,</span> <span class="kc">None</span><span class="p">)</span>
  File <span class="nb">&quot;/mnt/c/spot_v2_0/bblank_spot_v2_0_env/lib/python3.6/site-packages/grpc/_channel.py&quot;</span>, line <span class="m">729</span>, in <span class="n">_end_unary_response_blocking</span>
<span class="w">    </span><span class="k">raise</span> <span class="n">_InactiveRpcError</span><span class="p">(</span><span class="n">state</span><span class="p">)</span>
<span class="gr">grpc._channel._InactiveRpcError</span>: <span class="n">&lt;_InactiveRpcError of RPC that terminated with:</span>
<span class="x">        status = StatusCode.DEADLINE_EXCEEDED</span>
<span class="x">        details = &quot;Deadline Exceeded&quot;</span>
<span class="x">        debug_error_string = &quot;{&quot;created&quot;:&quot;@1585323526.280242100&quot;,&quot;description&quot;:&quot;Error received from peer ipv4:192.168.80.3:443&quot;,&quot;file&quot;:&quot;src/core/lib/surface/call.cc&quot;,&quot;file_line&quot;:1056,&quot;grpc_message&quot;:&quot;Deadline Exceeded&quot;,&quot;grpc_status&quot;:4}&quot;</span>
<span class="x">&gt;</span>
</pre></div>
</div>
<p>In addition to blocking calls, clients support non-blocking asynchronous calls. This can be useful in high performance applications where a thread of execution can not stall waiting for an RPC to complete. Python’s <a class="reference external" href="https://docs.python.org/3/library/concurrent.futures.html#future-objects">futures</a> architecture is used as the underpinning of asynchronous communication. See the <a class="reference internal" href="../../python/examples/get_robot_state_async/README.html"><span class="doc">get_robot_state_async programming example</span></a> for how to use these functions.</p>
<p>Let’s make an asynchronous call for the robot id and wait for the result from the returned future object:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">fut</span> <span class="o">=</span> <span class="n">id_client</span><span class="o">.</span><span class="n">get_id_async</span><span class="p">()</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">fut</span><span class="o">.</span><span class="n">result</span><span class="p">()</span>
<span class="go">serial_number: &quot;beta-BD-90490007&quot;</span>
<span class="go">species: &quot;spot&quot;</span>
<span class="go">...</span>
</pre></div>
</div>
</section>
<section id="inspecting-robot-state">
<h3>Inspecting robot state<a class="headerlink" href="#inspecting-robot-state" title="Permalink to this heading"></a></h3>
<p>The <code class="docutils literal notranslate"><span class="pre">robot-state</span></code> service contains dynamic information about the robot such as location, battery status, etc.</p>
<section id="services-and-authentication">
<h4>Services and Authentication<a class="headerlink" href="#services-and-authentication" title="Permalink to this heading"></a></h4>
<p>Before robot state can be retrieved, you need to authenticate to the robot. The majority of services require the user to be authenticated - this prevents random network attackers from being able to control the robot or intercept information which might be sensitive.</p>
<p>Assuming that the username is <code class="docutils literal notranslate"><span class="pre">user</span></code> and the password is <code class="docutils literal notranslate"><span class="pre">password</span></code>, issue the following command.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">robot</span><span class="o">.</span><span class="n">authenticate</span><span class="p">(</span><span class="s1">&#39;user&#39;</span><span class="p">,</span> <span class="s1">&#39;password&#39;</span><span class="p">)</span>
</pre></div>
</div>
<p>If you provided the wrong credentials, an exception will be raised.</p>
</section>
<section id="retrieving-robot-state">
<h4>Retrieving robot state<a class="headerlink" href="#retrieving-robot-state" title="Permalink to this heading"></a></h4>
<p>Now we can create a <code class="docutils literal notranslate"><span class="pre">RobotStateClient</span></code> for the <code class="docutils literal notranslate"><span class="pre">robot-state</span></code> service, and obtain information about Spot:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">state_client</span> <span class="o">=</span> <span class="n">robot</span><span class="o">.</span><span class="n">ensure_client</span><span class="p">(</span><span class="s1">&#39;robot-state&#39;</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">state_client</span><span class="o">.</span><span class="n">get_robot_state</span><span class="p">()</span>
<span class="go">power_state {</span>
<span class="go">  timestamp {</span>
<span class="go">    seconds: 1585324337</span>
<span class="go">    nanos: 644209920</span>
<span class="go">  }</span>
<span class="go">  ... a whole lot more</span>
</pre></div>
</div>
</section>
<section id="robot-state-was-a-message-messages-are-defined-by-protobufs">
<h4>Robot State was a message, messages are defined by protobufs<a class="headerlink" href="#robot-state-was-a-message-messages-are-defined-by-protobufs" title="Permalink to this heading"></a></h4>
<p>The structure of the robot state message retrieved above is defined by its <em>protobuf definition</em>. This is the language the robot speaks. Spot SDK completely exposes the protobuf, so to really understand Spot programming you want to look at and understand the protobufs. Take a look, they are right here in your distribution! <a class="reference external" href="../../protos/bosdyn/api/proto_reference.html#bosdyn-api-robot-state-proto">../../protos/bosdyn/api/robot_state.proto</a></p>
</section>
</section>
<section id="spot-s-frames">
<h3>Spot’s Frames<a class="headerlink" href="#spot-s-frames" title="Permalink to this heading"></a></h3>
<p>Often, it is useful to know about the position of Spot and how it relates to the world around it. To express this information, Spot uses frames to represent objects and locations (e.g. the “body” frame) and 3D transformations to describe the relationship between two frames using a translation vector and a rotation quaternion. See the <a class="reference internal" href="../concepts/geometry_and_frames.html"><span class="doc">Geometry and Frames</span></a> documentation for much more detail on frames and transformations, the math possible with 3D transformations, and the different frame’s Spot knows about.</p>
</section>
<section id="capture-and-view-camera-images">
<h3>Capture and View Camera Images<a class="headerlink" href="#capture-and-view-camera-images" title="Permalink to this heading"></a></h3>
<p>Spot has 5 “fisheye” cameras in addition to 5 depth cameras. Images can be captured from the these image sources. The ‘list_image_sources’ RPC returns valid camera source names.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">bosdyn.client.image</span> <span class="kn">import</span> <span class="n">ImageClient</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">image_client</span> <span class="o">=</span> <span class="n">robot</span><span class="o">.</span><span class="n">ensure_client</span><span class="p">(</span><span class="n">ImageClient</span><span class="o">.</span><span class="n">default_service_name</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">sources</span> <span class="o">=</span> <span class="n">image_client</span><span class="o">.</span><span class="n">list_image_sources</span><span class="p">()</span>
<span class="gp">&gt;&gt;&gt; </span><span class="p">[</span><span class="n">source</span><span class="o">.</span><span class="n">name</span> <span class="k">for</span> <span class="n">source</span> <span class="ow">in</span> <span class="n">sources</span><span class="p">]</span>
<span class="go">[&#39;back_depth&#39;, &#39;back_depth_in_visual_frame&#39;, &#39;back_fisheye_image&#39;, &#39;frontleft_depth&#39;, &#39;frontleft_depth_in_visual_frame&#39;, &#39;frontleft_fisheye_image&#39;, &#39;frontright_depth&#39;, &#39;frontright_depth_in_visual_frame&#39;, &#39;frontright_fisheye_image&#39;, &#39;left_depth&#39;, &#39;left_depth_in_visual_frame&#39;, &#39;left_fisheye_image&#39;, &#39;right_depth&#39;, &#39;right_depth_in_visual_frame&#39;, &#39;right_fisheye_image&#39;]</span>
</pre></div>
</div>
<p>Using the source names listed above, we can capture an image from one or more image sources. These images can be captured in RAW format or JPG format (with specified quality). Multiple images requested in a single RPC will be hardware time-synced with one another. Let’s retrieve the left_fisheye_image and display it (unless you are on MacOS or WSL)…</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">image_response</span> <span class="o">=</span> <span class="n">image_client</span><span class="o">.</span><span class="n">get_image_from_sources</span><span class="p">([</span><span class="s2">&quot;left_fisheye_image&quot;</span><span class="p">])[</span><span class="mi">0</span><span class="p">]</span>
<span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">PIL</span> <span class="kn">import</span> <span class="n">Image</span>
<span class="gp">&gt;&gt;&gt; </span><span class="kn">import</span> <span class="nn">io</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">image</span> <span class="o">=</span> <span class="n">Image</span><span class="o">.</span><span class="n">open</span><span class="p">(</span><span class="n">io</span><span class="o">.</span><span class="n">BytesIO</span><span class="p">(</span><span class="n">image_response</span><span class="o">.</span><span class="n">shot</span><span class="o">.</span><span class="n">image</span><span class="o">.</span><span class="n">data</span><span class="p">))</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">image</span><span class="o">.</span><span class="n">show</span><span class="p">()</span>
</pre></div>
</div>
</section>
<section id="configuring-motor-power-authority-software-e-stop">
<h3>Configuring “Motor Power Authority” (software E-Stop)<a class="headerlink" href="#configuring-motor-power-authority-software-e-stop" title="Permalink to this heading"></a></h3>
<p>Before Spot can power on, an independent <em>Motor Power Authority</em> must be correctly configured. We use the term “E-Stop” below and in our functions as shorthand for Motor Power Authority. The E-Stop is a key safety feature of Spot which lets operators kill motor power immediately if a situation calls for it. Note that in some circles the term “E-Stop” implies a hardware power short-circuit, hence our semantic dancing, as Spot’s Motor Power Authority is a networked software solution, not a hardware solution.</p>
<p>Let’s take a look at the initial E-Stop state of the robot by creating a client to the E-Stop service and requesting status:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">estop_client</span> <span class="o">=</span> <span class="n">robot</span><span class="o">.</span><span class="n">ensure_client</span><span class="p">(</span><span class="s1">&#39;estop&#39;</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">estop_client</span><span class="o">.</span><span class="n">get_status</span><span class="p">()</span>
<span class="go">stop_level: ESTOP_LEVEL_CUT</span>
<span class="go">stop_level_details: &quot;Not all endpoints are registered&quot;</span>
</pre></div>
</div>
<p>The <code class="docutils literal notranslate"><span class="pre">stop_level:</span> <span class="pre">ESTOP_LEVEL_CUT</span></code> line indicates that power will not be enabled since the E-Stop level is CUT.</p>
<p>The <code class="docutils literal notranslate"><span class="pre">stop_level_details:</span> <span class="pre">&quot;Not</span> <span class="pre">all</span> <span class="pre">endpoints</span> <span class="pre">are</span> <span class="pre">registered&quot;</span></code> line indicates that there are no E-Stop Endpoints registered. An E-Stop Endpoint is the client component of the E-Stop system which lets a user immediately kill power.</p>
<section id="create-and-register-an-e-stop-endpoint">
<h4>Create and register an E-Stop Endpoint<a class="headerlink" href="#create-and-register-an-e-stop-endpoint" title="Permalink to this heading"></a></h4>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">estop_endpoint</span> <span class="o">=</span> <span class="n">bosdyn</span><span class="o">.</span><span class="n">client</span><span class="o">.</span><span class="n">estop</span><span class="o">.</span><span class="n">EstopEndpoint</span><span class="p">(</span><span class="n">client</span><span class="o">=</span><span class="n">estop_client</span><span class="p">,</span> <span class="n">name</span><span class="o">=</span><span class="s1">&#39;my_estop&#39;</span><span class="p">,</span> <span class="n">estop_timeout</span><span class="o">=</span><span class="mf">9.0</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">estop_endpoint</span><span class="o">.</span><span class="n">force_simple_setup</span><span class="p">()</span>
</pre></div>
</div>
<p>E-Stop endpoints are expected to regularly check in to the robot to assure the robot is safely being controlled. If it has been more than <code class="docutils literal notranslate"><span class="pre">estop_timeout</span></code> seconds, the motor power will be cut. Tuning this number is important: too low a number, and the power may cut out due to transient network issues; too large a number and you run the risk of Spot operating without safe supervision.</p>
<p>The <code class="docutils literal notranslate"><span class="pre">force_simple_setup</span></code> call issues a few API calls to make your E-Stop Endpoint the sole endpoint in a new E-Stop configuration.</p>
<p>Let’s request E-Stop status after registering our endpoint:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">estop_client</span><span class="o">.</span><span class="n">get_status</span><span class="p">()</span>
<span class="go">endpoints {</span>
<span class="go">  endpoint {</span>
<span class="go">    role: &quot;PDB_rooted&quot;</span>
<span class="go">    name: &quot;my_estop&quot;</span>
<span class="go">    unique_id: &quot;0&quot;</span>
<span class="go">    timeout {</span>
<span class="go">      seconds: 9</span>
<span class="go">    }</span>
<span class="go">    cut_power_timeout {</span>
<span class="go">      seconds: 13</span>
<span class="go">    }</span>
<span class="go">  }</span>
<span class="go">  stop_level: ESTOP_LEVEL_CUT</span>
<span class="go">  time_since_valid_response {</span>
<span class="go">  }</span>
<span class="go">}</span>
<span class="go">stop_level: ESTOP_LEVEL_CUT</span>
<span class="go">stop_level_details: &quot;Endpoint requested stop&quot;</span>
</pre></div>
</div>
<p>Now an E-Stop Endpoint appears with the name <code class="docutils literal notranslate"><span class="pre">my_estop</span></code>. The endpoint itself says <code class="docutils literal notranslate"><span class="pre">ESTOP_LEVEL_CUT</span></code>, with a very long ago <code class="docutils literal notranslate"><span class="pre">time_since_valid_response</span></code>. No check-ins from the E-Stop Endpoint have happened yet. Both the endpoint and the E-Stop systems stop level is <code class="docutils literal notranslate"><span class="pre">ESTOP_LEVEL_CUT</span></code> - if a single Endpoint wants to cut power, the entire system will cut power.</p>
</section>
<section id="clear-the-e-stop">
<h4>Clear the E-Stop<a class="headerlink" href="#clear-the-e-stop" title="Permalink to this heading"></a></h4>
<p>To change E-Stop status and allow power, the endpoint needs to check in on a regular basis. We’ll use the <code class="docutils literal notranslate"><span class="pre">EstopKeepAlive</span></code> class to do these check-ins on a regular basis from a background thread.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">estop_keep_alive</span> <span class="o">=</span> <span class="n">bosdyn</span><span class="o">.</span><span class="n">client</span><span class="o">.</span><span class="n">estop</span><span class="o">.</span><span class="n">EstopKeepAlive</span><span class="p">(</span><span class="n">estop_endpoint</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">estop_client</span><span class="o">.</span><span class="n">get_status</span><span class="p">()</span>
<span class="go">endpoints {</span>
<span class="go">  endpoint {</span>
<span class="go">    role: &quot;PDB_rooted&quot;</span>
<span class="go">    name: &quot;my_estop&quot;</span>
<span class="go">    unique_id: &quot;0&quot;</span>
<span class="go">    timeout {</span>
<span class="go">      seconds: 9</span>
<span class="go">    }</span>
<span class="go">    cut_power_timeout {</span>
<span class="go">      seconds: 13</span>
<span class="go">    }</span>
<span class="go">  }</span>
<span class="go">  stop_level: ESTOP_LEVEL_NONE</span>
<span class="go">  time_since_valid_response {</span>
<span class="go">    nanos: 996009984</span>
<span class="go">  }</span>
<span class="go">}</span>
<span class="go">stop_level: ESTOP_LEVEL_NONE</span>
</pre></div>
</div>
<p>The <code class="docutils literal notranslate"><span class="pre">stop_level</span></code> is now <code class="docutils literal notranslate"><span class="pre">ESTOP_LEVEL_NONE</span></code>, indicating that power can start up.</p>
<p>Note that in many implementations, you should specify the <code class="docutils literal notranslate"><span class="pre">keep_running_cb</span></code> argument to EstopKeepAlive, a function called by the background thread to see if check-ins should continue. For example, an interactive UI should give the E-Stop system a <code class="docutils literal notranslate"><span class="pre">keep_running_cb</span></code> function which blocks until the UI thread has run a cycle. This prevents a frozen client from continuing to allow power to the robot.</p>
<p>See the Concept documents for more details about <a class="reference internal" href="../concepts/estop_service.html"><span class="doc">Spot’s software E-Stop Service</span></a>.</p>
</section>
</section>
<section id="taking-ownership-of-spot-leases">
<h3>Taking ownership of Spot (Leases)<a class="headerlink" href="#taking-ownership-of-spot-leases" title="Permalink to this heading"></a></h3>
<p>There’s one more step before powering on Spot’s motors, and that’s to acquire ownership of the robot. The robot can have multiple clients but only one can control the robot even as other clients may be requesting data or acting as E-Stop endpoints.</p>
<p>To gain control of the robot, a client needs to acquire a <code class="docutils literal notranslate"><span class="pre">Lease</span></code>. A valid lease must be presented with every mobility command to the robot. Leases can be returned when the client no longer wants to control the robot.</p>
<p>Like the E-Stop, lease-holders need to periodically check in with Spot to indicate that they are still actively controlling the robot. If it has been too long since a check-in, the robot will commence a Comms Loss Procedure - sitting down if it can, and then powering off.</p>
<p>Let’s make a <code class="docutils literal notranslate"><span class="pre">LeaseClient</span></code> for the <code class="docutils literal notranslate"><span class="pre">lease</span></code> service and list the current leases:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">lease_client</span> <span class="o">=</span> <span class="n">robot</span><span class="o">.</span><span class="n">ensure_client</span><span class="p">(</span><span class="s1">&#39;lease&#39;</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">lease_client</span><span class="o">.</span><span class="n">list_leases</span><span class="p">()</span>
<span class="go">[resource: &quot;all-leases&quot;</span>
<span class="go">lease {</span>
<span class="go">  resource: &quot;all-leases&quot;</span>
<span class="go">  epoch: &quot;ZBEwqFkjbTznJRxU&quot;</span>
<span class="go">  sequence: 1</span>
<span class="go">  client_names: &quot;root&quot;</span>
<span class="go">}</span>
<span class="go">lease_owner {</span>
<span class="go">}</span>
<span class="go">, resource: &quot;body&quot;</span>
<span class="go">lease {</span>
<span class="go">  resource: &quot;body&quot;</span>
<span class="go">  epoch: &quot;ZBEwqFkjbTznJRxU&quot;</span>
<span class="go">  sequence: 1</span>
<span class="go">  client_names: &quot;root&quot;</span>
<span class="go">}</span>
<span class="go">lease_owner {</span>
<span class="go">}</span>
<span class="go">, resource: &quot;mobility&quot;</span>
<span class="go">lease {</span>
<span class="go">  resource: &quot;mobility&quot;</span>
<span class="go">  epoch: &quot;ZBEwqFkjbTznJRxU&quot;</span>
<span class="go">  sequence: 1</span>
<span class="go">  client_names: &quot;root&quot;</span>
<span class="go">}</span>
<span class="go">lease_owner {</span>
<span class="go">}</span>
<span class="go">]</span>
</pre></div>
</div>
<p>The lease-able resources are listed: “body”, “mobility”, (”full-arm”, “gripper”, “arm” for robots with an arm). The “body” resource covers all of the motors on Spot and for most use-cases it is sufficient to issue all commands just using the “body” lease since services on Spot will break apart the lease to use the minimal set of resources necessary.</p>
<p>NOTE: the <code class="docutils literal notranslate"><span class="pre">lease_owner</span></code> field is empty since no one has acquired the body lease.</p>
<p>When taking lease control of Spot, the lease should first be acquired, and then the “keepalive” should be created to retain ownership of the lease resource.
Let’s acquire a lease, create the keepalive, and again list:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">lease</span> <span class="o">=</span> <span class="n">lease_client</span><span class="o">.</span><span class="n">acquire</span><span class="p">()</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">lease_keep_alive</span> <span class="o">=</span> <span class="n">bosdyn</span><span class="o">.</span><span class="n">client</span><span class="o">.</span><span class="n">lease</span><span class="o">.</span><span class="n">LeaseKeepAlive</span><span class="p">(</span><span class="n">lease_client</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">lease_client</span><span class="o">.</span><span class="n">list_leases</span><span class="p">()</span>
<span class="go">[resource: &quot;all-leases&quot;</span>
<span class="go">lease {</span>
<span class="go">  resource: &quot;all-leases&quot;</span>
<span class="go">  epoch: &quot;ZBEwqFkjbTznJRxU&quot;</span>
<span class="go">  sequence: 2</span>
<span class="go">  client_names: &quot;root&quot;</span>
<span class="go">}</span>
<span class="go">lease_owner {</span>
<span class="go">  client_name: &quot;HelloSpotClientlaptop-kbrandes01:hello_spot.py-32049&quot;</span>
<span class="go">}</span>
<span class="go">, resource: &quot;body&quot;</span>
<span class="go">lease {</span>
<span class="go">  resource: &quot;body&quot;</span>
<span class="go">  epoch: &quot;ZBEwqFkjbTznJRxU&quot;</span>
<span class="go">  sequence: 2</span>
<span class="go">  client_names: &quot;root&quot;</span>
<span class="go">}</span>
<span class="go">lease_owner {</span>
<span class="go">  client_name: &quot;HelloSpotClientlaptop-kbrandes01:hello_spot.py-32049&quot;</span>
<span class="go">}</span>
<span class="go">, resource: &quot;mobility&quot;</span>
<span class="go">lease {</span>
<span class="go">  resource: &quot;mobility&quot;</span>
<span class="go">  epoch: &quot;ZBEwqFkjbTznJRxU&quot;</span>
<span class="go">  sequence: 2</span>
<span class="go">  client_names: &quot;root&quot;</span>
<span class="go">}</span>
<span class="go">lease_owner {</span>
<span class="go">  client_name: &quot;HelloSpotClientlaptop-kbrandes01:hello_spot.py-32049&quot;</span>
<span class="go">}</span>
<span class="go">]</span>
</pre></div>
</div>
<p>After acquiring the “body” lease, you take ownership of the sub-resource “mobility”. For a robot with an arm, you will also take ownership of the sub-resources “full-arm”, “arm”, and “gripper” when acquiring the “body” lease.</p>
<p>NOTE: the lease keepalive object must remain in scope for the entire duration of the program that is using the lease for commands.</p>
</section>
<section id="powering-on-the-robot">
<h3>Powering on the robot<a class="headerlink" href="#powering-on-the-robot" title="Permalink to this heading"></a></h3>
<p>Now that you’ve authenticated to Spot, created an E-Stop endpoint, and acquired a lease, it’s time to power on the robot.</p>
<p>Make sure that the robot is in a safe spot, in a seated position, with a charged battery, and not connected to shore power.</p>
<p>The <code class="docutils literal notranslate"><span class="pre">power_on</span></code> helper function first issues a lower level power command to the robot and then waits for power command feedback. This command returns once the robot is powered on or throws an error if the power command fails for any reason. It typically takes several seconds to complete.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">robot</span><span class="o">.</span><span class="n">power_on</span><span class="p">(</span><span class="n">timeout_sec</span><span class="o">=</span><span class="mi">20</span><span class="p">)</span>
</pre></div>
</div>
<p>The robot object provides a method to check the power status of the robot. This just uses the RobotStateService to check the PowerState:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">robot</span><span class="o">.</span><span class="n">is_powered_on</span><span class="p">()</span>
<span class="go">True</span>
</pre></div>
</div>
</section>
<section id="establishing-timesync">
<h3>Establishing timesync<a class="headerlink" href="#establishing-timesync" title="Permalink to this heading"></a></h3>
<p>Timesync is required to coordinate clock skew between your device and Spot. From a safety perspective, this allows users to define a period of time for which a command will be valid. The robot class maintains a timesync thread. The <code class="docutils literal notranslate"><span class="pre">wait_for_sync</span></code> call below will start a timesync thread, and block until sync is established. After timesync is established, this thread will make periodic calls to maintain timesync. Each client is issued a clock identifier which is used to validate that the client has performed timesync, for services that require this functionality. The client library is written such that most implementation details of timesync are taken care of in the background.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">robot</span><span class="o">.</span><span class="n">time_sync</span><span class="o">.</span><span class="n">wait_for_sync</span><span class="p">()</span>
</pre></div>
</div>
</section>
<section id="commanding-the-robot">
<h3>Commanding the robot<a class="headerlink" href="#commanding-the-robot" title="Permalink to this heading"></a></h3>
<p>The RobotCommandService is the primary interface for commanding mobility. Mobility and mobility-related commands include <code class="docutils literal notranslate"><span class="pre">stand</span></code>, <code class="docutils literal notranslate"><span class="pre">sit</span></code>, <code class="docutils literal notranslate"><span class="pre">selfright</span></code>, <code class="docutils literal notranslate"><span class="pre">safe_power_off</span></code>, <code class="docutils literal notranslate"><span class="pre">velocity</span></code>, and <code class="docutils literal notranslate"><span class="pre">trajectory</span></code>. For this tutorial, we will just issue stand and safe power off commands.</p>
<p>The API provides a helper function to stand Spot. This command wraps several RobotCommand RPC calls. First a stand command is issued. The robot checks some basic pre-conditions (powered on, not faulted, not E-Stopped) and returns a command id. This command id can then be passed to the robot command feedback RPC. This call returns both high level feedback (”is the robot still processing the command?”) as well as command specific feedback (in the case of stand, “is the robot standing?”).</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">bosdyn.client.robot_command</span> <span class="kn">import</span> <span class="n">RobotCommandClient</span><span class="p">,</span> <span class="n">blocking_stand</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">command_client</span> <span class="o">=</span> <span class="n">robot</span><span class="o">.</span><span class="n">ensure_client</span><span class="p">(</span><span class="n">RobotCommandClient</span><span class="o">.</span><span class="n">default_service_name</span><span class="p">)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="n">blocking_stand</span><span class="p">(</span><span class="n">command_client</span><span class="p">,</span> <span class="n">timeout_sec</span><span class="o">=</span><span class="mi">10</span><span class="p">)</span>
</pre></div>
</div>
<p>The robot should now be standing. In addition, the stand command can be modified to control the height of the body as well as the orientation of the body with respect to the <strong>footprint frame</strong>. The footprint frame is a gravity aligned frame with its origin located at the geometric center of the feet. The Z axis up, and the X axis is forward.</p>
<p>The commands proto can be quite expressive, and therefore, if going beyond default parameters, non-trivial. To increase simplicity, Spot API provides several helper functions that combine Spot API RPC commands into single line functions.</p>
<p>We encourage you to experiment with these various parameters, referencing the <a class="reference external" href="../../protos/bosdyn/api/proto_reference.html#bosdyn-api-robot-command-proto">robot_command proto</a> parent class for general Boston Dynamics robots and the <a class="reference external" href="../../protos/bosdyn/api/proto_reference.html#bosdyn-api-spot-robot-command-proto">robot command proto</a> Spot subclass.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="c1"># Command Spot to rotate about the Z axis.</span>
<span class="o">&gt;&gt;&gt;</span> <span class="kn">from</span> <span class="nn">bosdyn.geometry</span> <span class="kn">import</span> <span class="n">EulerZXY</span>
<span class="o">&gt;&gt;&gt;</span> <span class="n">footprint_R_body</span> <span class="o">=</span> <span class="n">EulerZXY</span><span class="p">(</span><span class="n">yaw</span><span class="o">=</span><span class="mf">0.4</span><span class="p">,</span> <span class="n">roll</span><span class="o">=</span><span class="mf">0.0</span><span class="p">,</span> <span class="n">pitch</span><span class="o">=</span><span class="mf">0.0</span><span class="p">)</span>
<span class="o">&gt;&gt;&gt;</span> <span class="kn">from</span> <span class="nn">bosdyn.client.robot_command</span> <span class="kn">import</span> <span class="n">RobotCommandBuilder</span>
<span class="o">&gt;&gt;&gt;</span> <span class="n">cmd</span> <span class="o">=</span> <span class="n">RobotCommandBuilder</span><span class="o">.</span><span class="n">synchro_stand_command</span><span class="p">(</span><span class="n">footprint_R_body</span><span class="o">=</span><span class="n">footprint_R_body</span><span class="p">)</span>
<span class="o">&gt;&gt;&gt;</span> <span class="n">command_client</span><span class="o">.</span><span class="n">robot_command</span><span class="p">(</span><span class="n">cmd</span><span class="p">)</span>
<span class="c1"># Command Spot to raise up.</span>
<span class="o">&gt;&gt;&gt;</span> <span class="n">cmd</span> <span class="o">=</span> <span class="n">RobotCommandBuilder</span><span class="o">.</span><span class="n">synchro_stand_command</span><span class="p">(</span><span class="n">body_height</span><span class="o">=</span><span class="mf">0.1</span><span class="p">)</span>
<span class="o">&gt;&gt;&gt;</span> <span class="n">command_client</span><span class="o">.</span><span class="n">robot_command</span><span class="p">(</span><span class="n">cmd</span><span class="p">)</span>
</pre></div>
</div>
</section>
<section id="powering-off-the-robot">
<h3>Powering off the robot<a class="headerlink" href="#powering-off-the-robot" title="Permalink to this heading"></a></h3>
<p>Power off the robot using the <code class="docutils literal notranslate"><span class="pre">power_off</span></code> command. Note the preferred method is with <code class="docutils literal notranslate"><span class="pre">cut_immediately=False</span></code> where Spot will come to a stop and sit down gently before powering off. The other power off option cuts motor power immediately, which causes the robot to collapse.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">robot</span><span class="o">.</span><span class="n">power_off</span><span class="p">(</span><span class="n">cut_immediately</span><span class="o">=</span><span class="kc">False</span><span class="p">)</span>
</pre></div>
</div>
</section>
</section>
</section>


           </div>
          </div>
          <footer>
  

  <hr/>

  <div role="contentinfo">
    <p>
      
      &copy; Copyright 2025 Boston Dynamics. All rights reserved.
      <a href="https://www.bostondynamics.com/privacy-policy">Privacy Policy</a> | 
      <a href="https://www.bostondynamics.com/terms">Terms of Use</a>

    </p>
  </div> 

</footer>
        </div>
      </div>
    </section>
  </div>
  <script>
      jQuery(function () {
          SphinxRtdTheme.Navigation.enable(false);
      });
  </script>
    <!-- Theme Analytics -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=UA-XXXXXXX-1"></script>
    <script>
      window.dataLayer = window.dataLayer || [];
      function gtag(){dataLayer.push(arguments);}
      gtag('js', new Date());

      gtag('config', 'UA-XXXXXXX-1', {
          'anonymize_ip': false,
      });
    </script> 

</body>
</html>